package com.click369.crm.mapper;

import java.util.HashMap;
import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.click369.crm.pojo.CFunction;

public interface CFunctionMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(CFunction record);

    int insertSelective(CFunction record);

    CFunction selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(CFunction record);

    int updateByPrimaryKey(CFunction record);
    //根据职位id查询数据
    List<HashMap> getNodesByPid(@Param("pid")Integer pid);
    //根据角色id查询数据
    List<HashMap> getNodesByRid(@Param("rid")Integer rid);
    
    void deleteAllFunctionByRid(@Param("rid")Integer rid);
    
    void addFunctionByRid(@Param("rid")Integer rid,@Param("fids")Integer [] fids);
}